Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fallback executor support #171

Merged
merged 3 commits into from
Jun 28, 2019
Merged

fallback executor support #171

merged 3 commits into from
Jun 28, 2019

Conversation

Stebalien
Copy link
Member

@Stebalien Stebalien commented Jun 13, 2019

This adds fallback support to the HTTP executor. That way, we can try to run a command locally if the daemon is offline.

Note: This is an API breaking change which I will bubble up to both go-ipfs and filecoin. Specifically, http.NewClient now returns an Executor, not an http.Client. The correct way to use this client was to cast it to an executor.

We _need_ to do this before calling PreRun but it's also nice to do this before
bothering the server.
@Stebalien
Copy link
Member Author

This is a breaking change and will affect Filecoin. However, filecoin is
currently using this incorrectly anyways (breaking PreRun and PostRun).
This allows _trying_ to execute a command on a daemon, failing, and falling back
on another executor.
@Stebalien Stebalien merged commit f6f6a65 into master Jun 28, 2019
@Stebalien Stebalien deleted the feat/fallback branch June 28, 2019 16:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants